//index.js
//获取应用实例
const app = getApp()

Page({
  data: {
    go:"<",
    motto: 'Hello World',
    userInfo: {},
    hasUserInfo: false,
    canIUse: wx.canIUse('button.open-type.getUserInfo'),
    array: [
            ['张三138****4564', '北京直辖市朝阳区望京悠乐汇A座8011'],
            ['李四164****3719', '上海市的北京的石家庄巴拉巴拉'],
            ['王五134****9642', '保定东风东路999号河北软件学院'],
            ['赵六198****3217', '河北省乱七八糟市七上八下区']
           ],
           
    index:0,
    date: '2016-09-01',
    time: '12:01',
  },

  //事件处理函数
  bindViewTap: function() {
    wx.navigateTo({
      url: '../logs/logs'
    })
  },
  onLoad: function () {
    
  },
  bindDateChange: function (e) {
    
    this.setData({
      date: e.detail.value
    })
  }, 
  bindPickerChange: function (e) {
    this.setData({
      index: e.detail.value
    })
  },
  bindTimeChange: function (e) {
    this.setData({
      time: e.detail.value
    })
  },
  toSubscribe: function(){
    app.func.request("http://localhost/wxapi/test.php","GET", { "name": 3 }, this.ok);
  },
  ok:function(res){
    console.log(res);
  }
})
